Interface: BasePeerConnection
Hierarchy
BasePeerConnection
Properties
answerOptions
• answerOptions: undefined
| RTCAnswerOptions
bandwidth
• bandwidth: Bandwidth
close
• close: () => void
Type declaration
▸ (): void
Returns
void
configs
• configs: MediaConfig
[]
connectionState
• connectionState: RTCPeerConnectionState
createDataChannel
• createDataChannel: (label
: string
, dataChannelDict?
: RTCDataChannelInit
) => RTCDataChannel
Type declaration
▸ (label
, dataChannelDict?
): RTCDataChannel
Parameters
Name | Type |
---|---|
label | string |
dataChannelDict? | RTCDataChannelInit |
Returns
RTCDataChannel
getConfiguration
• getConfiguration: () => RTCConfiguration
Type declaration
▸ (): RTCConfiguration
Returns
RTCConfiguration
getDataChannelConfigs
• getDataChannelConfigs: () => DataChannelConfig
[]
Type declaration
▸ (): DataChannelConfig
[]
Returns
getTransceiverConfigs
• getTransceiverConfigs: () => TransceiverConfig
[]
Type declaration
▸ (): TransceiverConfig
[]
Returns
hasICECandidates
• hasICECandidates: boolean
iceConnectionState
• iceConnectionState: RTCIceConnectionState
iceGatheringState
• iceGatheringState: RTCIceGatheringState
offerOptions
• offerOptions: undefined
| RTCOfferOptions
peer
• peer: ExtendedRTCPeerConnection
polite
• polite: boolean
receivers
• receivers: RTCRtpReceiver
[]
references
• references: References
Reference of any logical associations to the peer connection for logging
restartIce
• restartIce: () => void
Type declaration
▸ (): void
Returns
void
senders
• senders: RTCRtpSender
[]
setConfiguration
• setConfiguration: undefined
| (configuration?
: RTCConfiguration
) => void
Only recently supported on some browser: https://caniuse.com/?search=setconfiguration
signalingState
• signalingState: RTCSignalingState
Methods
addConfig
▸ addConfig(peer
, initOrConfig
): DataChannelConfig
Parameters
Name | Type |
---|---|
peer | RTCPeerConnection |
initOrConfig | DataChannelConfig | DataChannelInit |
Returns
▸ addConfig(peer
, initOrConfig
): TransceiverConfig
Parameters
Name | Type |
---|---|
peer | RTCPeerConnection |
initOrConfig | TransceiverConfig | TransceiverInit |
Returns
▸ addConfig(peer
, initOrConfig
): TransceiverConfig
| DataChannelConfig
Parameters
Name | Type |
---|---|
peer | RTCPeerConnection |
initOrConfig | TransceiverConfig | DataChannelConfig | DataChannelInit | TransceiverInit |
Returns
TransceiverConfig
| DataChannelConfig
getStats
▸ getStats(selector?
): Promise
<RTCStatsReport
>
Parameters
Name | Type |
---|---|
selector? | null | MediaStreamTrack |
Returns
Promise
<RTCStatsReport
>
setLocalStream
▸ setLocalStream(stream
, target
, shouldSyncMedia?
): Promise
<void
>
Parameters
Name | Type |
---|---|
stream | undefined | MediaStream |
target | TransceiverConfigDirectionTuple [] |
shouldSyncMedia? | boolean |
Returns
Promise
<void
>
setReference
▸ setReference(key
, value
): void
Key/Value pair for referencing logical associations for logging
Parameters
Name | Type | Description |
---|---|---|
key | string | The key for the reference |
value | string | The value for the reference |
Returns
void